import { Button, Result } from 'antd';
import { FormattedMessage, formatMessage, Link } from 'umi';
import React from 'react';
import styles from './style.less';
const actions = (
  <div className={styles.actions}>
    <Link to="/home/center">
      <Button size="large">
        查看主页
      </Button>
    </Link>
    <Link to="/home/enterprise/register">
      <Button size="large" type="primary">
        创建公司
      </Button>
    </Link>
  </div>
);

const RegisterResult = ({ location }) => (
  <Result
    className={styles.registerResult}
    status="success"
    title={
      <div className={styles.title}>
        {location.state.username}
      </div>
    }
    subTitle='您已完成注册，请先登入到个人主页完善您的信息或者创建您的公司。'
    extra={actions}
  />
);

export default RegisterResult;
